import request from '@/utils/request'

//1. 查询所有学生
export function findAll() {
  return request({
    url: '/student/list',
    method: 'get',
  })
}
//2. 分页查询
export function findByPage(page,pageSize) {
  return request({
    url: `/student/findByPage/${page}/${pageSize}`,
    method: 'get',
  })
}
//3. 条件查询带分页
export function search(page,pageSize,data) {
  return request({
    url: `/student/search/${page}/${pageSize}`,
    method: 'post',
    data
  })
}
//4. 保存学生
export function save(url,data) {
  return request({
    url,
    method: 'post',
    data
  })
}
//5. 删除学生
export function delStud(sids) {
  return request({
    url: `/student/delete/${sids}`,
    method: 'delete',
  })
}
